package com.bsdsma.fengheguaiapp.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;

/**
 * 酒店房型表
 */
@Data
@Entity
@Table(name = "roominfo")
@TableName("roominfo")
@KeySequence(dbType = DbType.MYSQL)
public class Roominfo implements Serializable {
    private static final long serialVersionUID = 1L;
    /**
     * 主键ID 自增
     */
    @Id
    @Column(length = 20)
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @TableId(type = IdType.AUTO)
    private Long id;
    @Column(name = "roomType", columnDefinition = "varchar(200) not null DEFAULT ''")
    private String roomType;
    @Column(name = "price", columnDefinition = "int(11) not null DEFAULT 0")
    private Integer price;
    @Column(name = "rNum", columnDefinition = "int(11) not null DEFAULT 0")
    private Integer rNum;
    /**
     * 创建时间
     */
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date ct;
    /**
     * 更新时间
     */
    @JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date ut;

    /**
     * 0正常 -1删除
     */
    @Column(nullable = false)
    private Integer status;
}